import 'package:flutter/material.dart';

class TestPageStory extends StatelessWidget {
  // 路径
  static const routeName = "/storyTest";

  final String title;
  final String msg;

  // 接收自定义的传参
  const TestPageStory({Key? key, required this.title, required this.msg}) : super(key: key);

  @override
  Widget build(BuildContext context) {
    return MaterialApp(
      home: Scaffold(
        appBar: AppBar(
          title: Text(title),
        ),
        body: Text(msg),
      ),
    );
  }
}

class _TestPageStory extends StatefulWidget {
  const _TestPageStory({Key? key}) : super(key: key);

  @override
  _TestPageStoryState createState() => _TestPageStoryState();
}

class _TestPageStoryState extends State<_TestPageStory> {
  @override
  Widget build(BuildContext context) {
    return Container();
  }
}

class StoryArguments {
  final String title;
  final String msg;

  StoryArguments(this.title, this.msg);
}
